import service from '@/core/net/request'
import { queryParams } from '@/core/utils/tools'

export function getGoodsCommentList(page, query = {}) {
  let r = queryParams(query)
  return service.get(`/api/admin/goods_comment/${page}${r}`)
}

export function updateGoodsCommentStatus(id, status) {
  return service.post(`/api/admin/goods_comment/${id}/update_status`, {
    status,
  })
}

export function reviewGoodsComment(id, data) {
  return service.post(`/api/admin/goods_comment/review/${id}`, {
    data,
  })
}
